home *** CD-ROM | disk | FTP | other *** search
/ Software of the Month Club 2000 October / Software of the Month - Ultimate Collection Shareware 277.iso / pc / PROGRAMS / UTILITY / WINLINUX / DATA1.CAB / programs_-_include / ASM-I386 / LITHIUM.H < prev    next >
C/C++ Source or Header  |  1999-09-17  |  1KB  |  46 lines

  1. #ifndef __I386_LITHIUM_H
  2. #define __I386_LITHIUM_H
  3.  
  4. #include <linux/config.h>
  5.  
  6. /*
  7.  * Lithium is the I/O ASIC on the SGI 320 and 540 Visual Workstations
  8.  */
  9.  
  10. #define    LI_PCI_A_PHYS        0xfc000000    /* Enet is dev 3 */
  11. #define    LI_PCI_B_PHYS        0xfd000000    /* PIIX4 is here */
  12.  
  13. /* see set_fixmap() and asm/fixmap.h */
  14. #define LI_PCIA_VADDR   (fix_to_virt(FIX_LI_PCIA))
  15. #define LI_PCIB_VADDR   (fix_to_virt(FIX_LI_PCIB))
  16.  
  17. /* Not a standard PCI? (not in linux/pci.h) */
  18. #define    LI_PCI_BUSNUM    0x44            /* lo8: primary, hi8: sub */
  19. #define LI_PCI_INTEN    0x46
  20.  
  21. #ifdef CONFIG_X86_VISWS_APIC
  22. /* More special purpose macros... */
  23. extern __inline void li_pcia_write16(unsigned long reg, unsigned short v)
  24. {
  25.     *((volatile unsigned short *)(LI_PCIA_VADDR+reg))=v;
  26. }
  27.  
  28. extern __inline unsigned short li_pcia_read16(unsigned long reg)
  29. {
  30.      return *((volatile unsigned short *)(LI_PCIA_VADDR+reg));
  31. }
  32.  
  33. extern __inline void li_pcib_write16(unsigned long reg, unsigned short v)
  34. {
  35.     *((volatile unsigned short *)(LI_PCIB_VADDR+reg))=v;
  36. }
  37.  
  38. extern __inline unsigned short li_pcib_read16(unsigned long reg)
  39. {
  40.     return *((volatile unsigned short *)(LI_PCIB_VADDR+reg));
  41. }
  42. #endif
  43.  
  44. #endif
  45.  
  46.